package pro.shushi.pamirs.demo.api.service;

import pro.shushi.pamirs.core.common.standard.service.StandardModelService;
import pro.shushi.pamirs.demo.api.model.DemoItem;
import pro.shushi.pamirs.framework.connectors.data.sql.query.LambdaQueryWrapper;
import pro.shushi.pamirs.meta.annotation.Fun;
import pro.shushi.pamirs.meta.annotation.Function;
import pro.shushi.pamirs.meta.api.dto.condition.Pagination;

import java.util.List;

@Fun(DemoItemService.FUN_NAMESPACE)
public interface DemoItemService extends StandardModelService<DemoItem> {

    String FUN_NAMESPACE = "demo.DemoItemService";

    @Function
    @Override
    DemoItem create(DemoItem data);

    @Function
    @Override
    DemoItem update(DemoItem data);

    @Function
    @Override
    Pagination<DemoItem> queryPage(Pagination<DemoItem> page, LambdaQueryWrapper<DemoItem> queryWrapper);

    @Function
    @Override
    DemoItem queryOne(DemoItem query);

    @Function
    @Override
    DemoItem queryOneByWrapper(LambdaQueryWrapper<DemoItem> queryWrapper);

    @Function
    @Override
    List<DemoItem> queryListByWrapper(LambdaQueryWrapper<DemoItem> queryWrapper);

    @Function
    @Override
    Long count(LambdaQueryWrapper<DemoItem> queryWrapper);

}
